package cn.com.api.mapper.base;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.*;

import cn.com.api.entity.ApiU_bonus_push;

//DAO
public interface U_bonus_pushMapperBase {

	//根据id查看
    @Select("SELECT * FROM U_BONUS_PUSH  WHERE ID = #{ID}")
	public ApiU_bonus_push findU_bonus_pushById(Integer id);
	
    //查看数据集
    @Select("SELECT * FROM U_bonus_push")
	public List<ApiU_bonus_push> findU_bonus_pushs();
	
	//添加
    @Insert("INSERT INTO U_BONUS_PUSH (USER_ID, COUNT, SUMMY, TITLE, ADD_TIME, IS_EXPIRE, TYPE, EXT1, EXT2, EXT3, EXT4, EXT5, DURING_TIME, COUNT_CHARGE, COUNT_FREE, SHOW_TIMES, LATITUDE, LONGITUDE) VALUES (#{USER_ID}, #{COUNT}, #{SUMMY}, #{TITLE}, #{ADD_TIME}, #{IS_EXPIRE}, #{TYPE}, #{EXT1}, #{EXT2}, #{EXT3}, #{EXT4}, #{EXT5}, #{DURING_TIME}, #{COUNT_CHARGE}, #{COUNT_FREE}, #{SHOW_TIMES}, #{LATITUDE}, #{LONGITUDE})")
 	@Options(useGeneratedKeys = true, keyProperty = "id")
    public int insertU_bonus_push(ApiU_bonus_push u_bonus_push);
  	
	//修改
    @Update("UPDATE U_BONUS_PUSH SET USER_ID = #{USER_ID}, COUNT = #{COUNT}, SUMMY = #{SUMMY}, TITLE = #{TITLE}, ADD_TIME = #{ADD_TIME}, IS_EXPIRE = #{IS_EXPIRE}, TYPE = #{TYPE}, EXT1 = #{EXT1}, EXT2 = #{EXT2}, EXT3 = #{EXT3}, EXT4 = #{EXT4}, EXT5 = #{EXT5}, DURING_TIME = #{DURING_TIME}, COUNT_CHARGE = #{COUNT_CHARGE}, COUNT_FREE = #{COUNT_FREE}, SHOW_TIMES = #{SHOW_TIMES}, LATITUDE = #{LATITUDE}, LONGITUDE = #{LONGITUDE} WHERE ID = #{ID}")
    public int updateU_bonus_push(ApiU_bonus_push u_bonus_push);
    
    //删除
    @Delete("DELETE FROM U_BONUS_PUSH  WHERE ID = #{ID}")
    public int deleteU_bonus_push(Integer id);
 
    // Foreign keys revelant		
		

	//region Indexs revelant
    
    
    
}


